Spectrometry is a well-known technique used to identify the characteristics of gas, liquid, and solid samples, wherein light is directed at a sample and the light leaving the sample is then picked up by a photosensitive detector to be analyzed for changes in wavelength. These changes provide information regarding the composition of the sample, its chemical bonds, and other features. As an example, FIG. 1 illustrates a spectrum (sometimes referred to as an “exposure”) obtained from a Raman spectrometer, wherein a laser is directed at a sample and the detector captures data regarding the light scattered from the sample. Here the spectrum data is presented as a plot of light intensity versus light wavelength, with wavelength being represented by pixel numbers from the detector (which is made of an array of detector elements/pixels). The spectrum can be compared to libraries of previously-obtained reference spectra to obtain information about the sample, such as its identity and characteristics.
A commonly encountered problem in the field of spectrometry is that spurious detector readings often arise, leading to distortions in captured spectra. As an example, FIG. 2 illustrates an exposure taken from the same sample as in FIG. 1, but at a slightly later time. While FIGS. 1 and 2 appear quite similar overall, there are some notable differences—in particular, FIG. 2 bears an intensity spike at approximately pixel 650 which is absent in the spectrum of FIG. 1. A spike of this nature is often caused by transient cosmic rays, which impinge upon and excite one or more pixels/elements of the detector and thus give rise to spurious intensity readings at these pixels. Such spurious spikes can be mistaken for “real” spikes—those generated by scattered light from the sample—and they can therefore lead to errors in the interpretation of the spectrum data.
To diminish the effect of spurious spikes that may be present in an exposure, it is common to take multiple exposures of the specimen (as with FIGS. 1 and 2), average their spectra, and then perform final analysis on the averaged spectrum. Averaging of the spectra will generally reduce the intensities of spurious readings, but will not fully eliminate them. Further, averaging of multiple exposures increases the chances that spurious readings present in other exposures will also be introduced into the average, leading to further distortion in the spectrum to be analyzed. It would therefore be useful to have additional methods available for identifying and/or eliminating cosmic ray spikes and other unwanted artifacts from the spectra.